package com.example.qxfw.common.mapper;


import com.baomidou.dynamic.datasource.annotation.DS;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.qxfw.common.entity.qx.SmallScaleStation;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/************************************
*
* @author : HuangDeYin Jolly
* @since : JDK 11
* @Date : 2023/7/6  星期四   8:38
* @description : 此类用来
***************************************/
@Mapper
@DS("master")
public interface SmallscaleStationMapperXml extends BaseMapper<SmallScaleStation>, CoMapper<SmallScaleStation> {
    /**
     * insert record to table
     * @param record the record
     * @return insert count
     */
    int insert(SmallScaleStation record);

    /**
     * insert record to table selective
     * @param record the record
     * @return insert count
     */
    int insertSelective(SmallScaleStation record);

    List<SmallScaleStation> getDistinctStationIdByCity(String city);

    List<SmallScaleStation> getByLongItude(@Param("city") String city, @Param("jd") Double jd, @Param("wd") Double wd);

    List<SmallScaleStation> querySmallScaleStation(@Param("stationId") String stationId, @Param("stationName") String stationName, @Param("city") String city, @Param("county") String county);

    /************************
     * @Author : HuangDeYin Jolly
     * @Description :根据stationId查询出国家站的stationId
     * @return java.util.List<com.example.demo.common.entity.qx.SmallScaleStation> :
     ************************/

    List<SmallScaleStation> queryCountyByStationId(@Param("stationId") String stationId);

    List<SmallScaleStation> queryStationIdByCounty(@Param("county") String county);

    List<SmallScaleStation> queryStatisticalChartOfAgriculturalStationElements(@Param("stationName") String stationName);


}